package com.practice.response;

/**
 * @author kayn
 * @create 2023-10-09 上午 10:55
 */
public enum ResponseEnum {
    SUCCESS(true, 200, "成功"),
    UNKNOWN_ERROR(false, 20001, "未知异常"),
    PARAM_ERROR(false, 20002, "参数错误"),
    UNAUTHORIZED_ERROR(false, 406, "无权限"),
    FORBID_ERROR(false, 401, "请登陆"),
    USERINFO_ERROR(false, 403, "用户信息错误");

    private Boolean success;
    private Integer code;
    private String message;

    private ResponseEnum(boolean success, Integer code, String message) {
        this.success = success;
        this.code = code;
        this.message = message;
    }

    public Boolean getSuccess() {
        return this.success;
    }

    public void setSuccess(Boolean success) {
        this.success = success;
    }

    public Integer getCode() {
        return this.code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMessage() {
        return this.message;
    }

    public void setMessage(String message) {
        this.message = message;
    }
}
